<?php
namespace App\Event\UserPay;

use App\Event\Event;
use App\Repository\UserRepository;
use App\Repository\LevelRepository;

// 支付失败事件
class StatusNoEvent extends Event
{
    public $pay;
    
    public $money;
    
    public $user;
    
    // 用户及金额
    public function __construct($pay)
    {
        $this->pay  = $pay;
        $this->money = $pay->money;
        $this->user = UserRepository::make($this->pay->user);
    }
}